<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="f"%>
<%@ taglib uri="/mytag" prefix="yjd"%>
<body>
<div class="wrap">
    <div class="h_a">搜索</div>
    <form action="${requestScope.FPWEB.rootPath }/order/repayment/list${requestScope.FPWEB.urlStuff}"  method="get" autocomplete="off">
        <div class="search_type cc">
            <label>订单ID：</label>
            <input name="order_id" type="text" class="input length_3 mr10" value="${maps.order_id}">
            <label>订单编号：</label>
            <input name="order_no" type="text" class="input length_3 mr10" value="${maps.order_no}">
            <label>借款人姓名：</label>
            <input name="id_name" type="text" class="input length_3 mr10" value="${maps.id_name}">
            <label>还款状态：</label>
            <select name="repayment_status">
                <option value="">全部</option>
                <option ${maps.repayment_status==1?"selected='selected'":"" } value="1">已还</option>
                <option ${maps.repayment_status==0?"selected='selected'":"" } value="0">未还</option>
            </select>
            <button type="submit" class="btn btn_submit length_1">搜索</button>
        </div>
    </form>

    <div class="table_list">
        <table width="100%">
            <thead>
            <tr>
                <td>订单ID</td>
                <td>订单编号</td>
                <td>借款人</td>
                <td>当前期数</td>
                <td>应还款日期</td>
                <td>实际还款时间</td>
                <td>还款状态</td>
                <td>还款金额</td>
                <td>罚息金额</td>
                <td>减免金额</td>
                <td>商户</td>
                <td>操作</td>
            </tr>
            </thead>
            <tbody>
            <c:forEach items="${pager.pagerModel.dataList }" var="item" varStatus="i">
                <tr>
                    <td>${item.order_id}</td>
                    <td>${item.order_no}</td>
                    <td>${item.id_name}</td>
                    <td>${item.period}</td>
                    <td>
                        ${item.strMap.estimation_repayment_time}
                        <c:if test="${item.strMap.overdueDay != null}">
                            <font color="red">（逾期${item.strMap.overdueDay}天）</font>
                        </c:if>
                    </td>
                    <td>
                        <c:if test="${item.repayment_status==1}"><yjd:jstl_date value="${item.repayment_time }" parttern="yyyy-MM-dd HH:mm:ss"/></c:if>
                    </td>
                    <td>
                        <c:if test="${item.repayment_status == 0}">未还</c:if>
                        <c:if test="${item.repayment_status == 1}">已还</c:if>
                        <c:if test="${item.repayment_status == 2}">取消</c:if>
                    </td>
                    <td>${item.repayment_amount}</td>
                    <td>${item.overdue_price}</td>
                    <td>${item.discount_amount}</td>
                    <td>${item.org_name}</td>
                    <td>
                        <a href='<yjd:url url="/order/detail/${item.order_id }"/>' class="btn mr10">详细信息</a>
                    </td>
                </tr>
            </c:forEach>
            </tbody>
        </table>

        <!-- 分页 -->
        <%@ include file="../public/pager/pager.pagination.jsp" %>
    </div>

</div>
<script>
    YJD.use('AppAdminCommon');
</script>
</body>